from flask import Blueprint, render_template

from service.ArticleService import get_article_group_by_month

view_archive = Blueprint('view_archive', __name__)
view_archive.url_prefix = '/view'


@view_archive.route('/archive')
def index():
    archives = get_article_group_by_month()
    return render_template('public/style1/archive.html', archives=archives)
